home *** CD-ROM | disk | FTP | other *** search
/ PCGUIA 117 / PC Guia 117.iso / Software / Produtividade / Software2 / Product4 / Setup.exe / drupal-4.6.0 / cron.php < prev    next >
Encoding:
PHP Script  |  2005-01-09  |  749 b   |  33 lines

  1. <?php
  2. // $Id: cron.php,v 1.28 2005/01/09 09:22:38 dries Exp $
  3.  
  4. /**
  5.  * @file
  6.  * Handles incoming requests to fire off regularly-scheduled tasks (cron jobs).
  7.  */
  8.  
  9. include_once 'includes/bootstrap.inc';
  10. include_once 'includes/common.inc' ;
  11.  
  12. // If not in 'safe mode', increase the maximum execution time:
  13. if (!ini_get('safe_mode')) {
  14.   set_time_limit(240);
  15. }
  16.  
  17. // Check if the last cron run completed
  18. if (variable_get('cron_busy', false)) {
  19.   watchdog('cron', t('Last cron run did not complete.'), WATCHDOG_WARNING);
  20. }
  21. else {
  22.   variable_set('cron_busy', true);
  23. }
  24.  
  25. // Iterate through the modules calling their cron handlers (if any):
  26. module_invoke_all('cron');
  27.  
  28. // Clean up
  29. variable_set('cron_busy', false);
  30. watchdog('cron', t('Cron run completed'));
  31.  
  32. ?>
  33.